<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>图形化场景编辑器</title>
    <link rel="stylesheet" href="editor.css">
    <style>
        body {
            font-family: Arial, sans-serif;
            display: flex;
            margin: 0;
            padding: 0;
            height: 100vh;
        }

        #sidebar {
            width: 200px;
            background-color: #f4f4f4;
            border-right: 1px solid #ddd;
            padding: 20px;
            display: flex;
            flex-direction: column;
        }

        #sidebar button {
            margin-bottom: 10px;
            padding: 10px;
            width: 100%;
        }

        #editor {
            flex: 1;
            padding: 20px;
            position: relative;
            overflow: auto;
            background-color: #f9f9f9;
        }

        .scene,
        .option {
            background-color: #fff;
            border: 1px solid #ccc;
            border-radius: 8px;
            padding: 10px;
            position: absolute;
            resize: both;
            overflow: hidden;
        }

        .scene {
            width: 200px;
            height: 100px;
        }

        .option {
            width: 150px;
            height: 50px;
            background-color: #f0f0f0;
        }

        .connect-point {
            width: 10px;
            height: 10px;
            background-color: #007bff;
            border-radius: 50%;
            position: absolute;
            cursor: pointer;
        }

        .line {
            position: absolute;
            background-color: #007bff;
            width: 2px;
        }
    </style>
</head>

<body>
    <div id="sidebar">
        <button onclick="newScene()">新建场景</button>
        <button onclick="newOption()">新建选项</button>
        <button onclick="exportData()">导出</button>
        <button onclick="importData()">导入</button>
    </div>
    <div id="editor"></div>
    <script src="editor.js"></script>
</body>

</html>